<?php
    session_start();
    if(isset($_SESSION["MaTaiKhoan"]) == false)
    {
        echo '<script type = "text/javascript">';
        echo 'location = "index.php";';
        echo '</script>';
    }
    if($_SESSION["MaLoaiTaiKhoan"] != 2)
    {
        session_destroy();
        echo '<script type = "text/javascript">';
        echo 'location = "index.php";';
        echo '</script>';
        
    }
        
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>IN ADMIN PANEL | Powered by INDEZINER</title>
<link rel="stylesheet" type="text/css" href="style.css" />
<script type="text/javascript" src="jquery.min.js"></script>
<script type="text/javascript" src="ddaccordion.js"></script>
<script type="text/javascript">
ddaccordion.init({
	headerclass: "submenuheader", //Shared CSS class name of headers group
	contentclass: "submenu", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click", "clickgo", or "mouseover"
	mouseoverdelay: 200, //if revealtype="mouseover", set delay in milliseconds before header expands onMouseover
	collapseprev: true, //Collapse previous content (so only one open at any time)? true/false 
	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc] [] denotes no content
	onemustopen: false, //Specify whether at least one header should be open always (so never all headers closed)
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: true, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	togglehtml: ["suffix", "<img src='images/plus.gif' class='statusicon' />", "<img src='images/minus.gif' class='statusicon' />"], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
	animatespeed: "fast", //speed of animation: integer in milliseconds (ie: 200), or keywords "fast", "normal", or "slow"
	oninit:function(headers, expandedindices){ //custom code to run when headers have initalized
		//do nothing
	},
	onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
		//do nothing
	}
})
</script>
<script src="jquery.jclock-1.2.0.js.txt" type="text/javascript"></script>
<script type="text/javascript" src="jconfirmaction.jquery.js"></script>


<script language="javascript" type="text/javascript" src="niceforms.js"></script>
<link rel="stylesheet" type="text/css" media="all" href="niceforms-default.css" />



   

</head>
<body>
<div id="main_container">

	<div class="header">
    
        <?php include("template/header.php");?>
    
    </div><!--end header-->
    
    <div class="main_content">
    
        <div class="menu" id="menu">
        
            <?php include("template/menu.php");?>
                            
        </div> <!--end menu-->
                    
                    
                    
                    
    <div class="center_content">  
    
        <!--<div class="left_content">
    
    		<?php include("template/left_content.php");?>
            
        </div><!--end left content-->  
    
    <div class="right_content" style="width: 850px;">            
        
        <?php   
        
                //nếu có biến trả về search user       
                if(isset($_REQUEST["txtSearch"]) == true)
				{
					include("pages/pSearchUS.php");
				}
				 if(isset($_REQUEST["txtSearchSP"]) == true)
                {
                    include("pages/pSearchSP.php");
                }
                 if(isset($_REQUEST["txtSearchHD"]) == true)
                {
                    include("pages/pSearchHD.php");
                }
				else
				{
				//Xu ly bien act luc load trang
				if(isset($_REQUEST["act"]) == false)
				{
					$act = 1;	
				}
				else
				{
					$act = $_REQUEST["act"];	
				}
				switch($act)
				{
				   
					case 1: 
						include("pages/pHello.php");
						break;
					case 2:
						include("pages/pAllUser.php");
						break;
					case 3:
						include("pages/pUserSeller.php");
						break;
					case 4:
						include("pages/pUserBuyer.php");
						break;
                    case 5:
						include("pages/pUserBlock.php");
						break;
                    case 6:
						include("pages/pUserBanned.php");
						break;
                    case 7:
                        include("code/xlBlock.php");
                        break;
                    case 8;
                        include("code/xlBanned.php");
                        break;
                    case 9:
                        include("pages/pqlsanpham.php");
                        break;
                    case 10:
                        include("pages/psuasp.php");
                        break;
                    case 11:
                        include("pages/pxoasp.php");
                        break;
                    case 12:
                        include("code/xlsuasp.php");
                        break;
                    case 13:
                        include("code/xlxoasp.php");
                        break;
                    case 14:
                        include("pages/pqlDonDatHang.php");
                        break;
                    case 15:
                        include("code/xlDonDatHang.php");
                        break;
                    case 16:
                        include("pages/pQLGiaoDien.php");
                        break;          
					default:
						include("pages/pHello.php");
				}
				}
			?>            
     <br />
     <br />
     <hr />
     <br />
     <h2>Cảnh báo bài viết vi phạm!</h2>
      
     <div class="warning_box">
        --------------------------------------------------------------------------------------------
     </div>  
             
      
     
    </div><!-- end of right content-->
            
                    
  </div>   <!--end of center content -->               
                    
                    
    
    
    <div class="clear"></div>
    </div> <!--end of main content-->

</div>		
</body>
</html>